package io.github.uicdb.et.net;

import net.minecraft.network.RegistryFriendlyByteBuf;
import net.minecraft.network.codec.StreamCodec;
import net.minecraft.network.syncher.EntityDataSerializer;
import org.jetbrains.annotations.NotNull;

public class ElementDataSerializer implements EntityDataSerializer<ElementAttachmentData>{
    public static final ElementDataSerializer INSTANCE = new ElementDataSerializer();
    @Override
    public @NotNull StreamCodec<? super RegistryFriendlyByteBuf, ElementAttachmentData> codec() {
        return ElementAttachmentData.STREAM_CODEC;
    }

    @Override
    public @NotNull ElementAttachmentData copy(ElementAttachmentData elementAttachmentData) {
        return elementAttachmentData.copy();
    }
}
